package com.zabra.zl.ui.buy.contract;

import com.zabra.zl.base.BaseView;
import com.zabra.zl.data.DetailsDealBean;
import com.zabra.zl.data.SimpleBean;
import com.zabra.zl.data.StockBean;

import io.reactivex.Flowable;
import okhttp3.RequestBody;
import retrofit2.Call;

public interface BuyContract {
    interface Model {
        Flowable<StockBean> getData(String sharesCode, int bpOrderId);

        Call<DetailsDealBean> getData(RequestBody body);

        Call<SimpleBean> getData(String sharesCode, String sharesName, String entrustPrice, String entrustNum, String entrustProportion, String bpOrderId);
    }

    interface View extends BaseView {
        @Override
        void showLoading();

        @Override
        void hideLoading();

        @Override
        void onError(Throwable throwable);

        void onSuccess(StockBean bean);

        void onSuccessFresh(StockBean bean);

        void onSuccess(DetailsDealBean bean);

        void onSuccess(SimpleBean bean);
    }

    interface Presenter {
        void getData(String sharesCode, int bpOrderId);

        void getDataFresh(String sharesCode, int bpOrderId);

        void getData(RequestBody body);

        void getData(String sharesCode, String sharesName, String entrustPrice, String entrustNum, String entrustProportion, String bpOrderId);
    }
}
